package koction.model.seller;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import koction.model.product.ProductVO;
@Service
public class SellerServiceImpl implements SellerService {
	@Resource(name="sellerDaoImpl")
	private SellerDao sellerDao;
	
	/* (non-Javadoc)
	 * @see koction.model.seller.SellerService#getProductList(koction.model.seller.SellerVO)
	 */
	@Override
	public List<ProductVO> getProductList(SellerVO sellerVO){
		return sellerDao.getProductList(sellerVO);
	}
	@Override
	public ProductVO updateProductView(int productId) {
		return sellerDao.updateProductView(productId);
	}
	@Override
	public List<String> registerProductView() {
		return sellerDao.registerProductView();
	}
	@Override
	public void updateProduct(ProductVO pvo) {
		sellerDao.updateProduct(pvo);
	}
	@Override
	public void delelteProduct(String productId) {
		sellerDao.delelteProduct(productId);
	}
	@Override
	public List<ProductVO> getProductListOrderByPrice(SellerVO sellerVO) {
		return sellerDao.getProductListOrderByPrice(sellerVO);
	}
	@Override
	public List<ProductVO> getProductListOrderByDate(SellerVO sellerVO) {
		return sellerDao.getProductListOrderByDate(sellerVO);
	}
	@Override
	public List<ProductVO> getProductListOrderBySalesVolume(SellerVO sellerVO) {
		return sellerDao.getProductListOrderBySalesVolume(sellerVO);
	}
	
	@Override
	public void registerProduct(ProductVO pvo) throws Exception {
		sellerDao.registerProduct(pvo);
		
	}
	@Override
	public List<String> getCategoryView() throws Exception {
		
		return sellerDao.registerProductView();
	}
	@Override
	public SellerVO updateSellerView(String sellerId) throws Exception {
		
		return sellerDao.updateSellerView(sellerId);
	}
	@Override
	public void updateSeller(SellerVO svo) throws Exception {
		sellerDao.updateSeller(svo);
		
	}
}	
